<?php
/*
	Auto is batch jobs or any process that does not have a UI.
set_time_limit(0); means no time limit

http://localhost/zend/veneer2/auto/link/yahoo
*/
abstract class Veneer_Controller_Auto extends Zend_Controller_Action
{
/*	Variables
	array - jsZone
*/
	protected $_veneer_parms;	// array of parms
	protected $config;	// array of parms
	protected $_veneer_log;	// array of parms

	function init()
	{
		$this->view->baseUrl = $this->_request->getBaseUrl();
		foreach($this->_dbArray as $tableName)
		{
			Zend_Loader::loadClass($tableName,'modules/'. $this->_moduleName . '/models');
		}
		$this->_veneer_parms = $this->_getAllParams();
		// load config.ini

		$this->_helper->LayoutManager->disableLayouts();
		$registry = Zend_Registry::getInstance();
		$this->_veneer_log = $registry->get('veneerLog');
		$this->_veneer_log->info("test run 2");
/*
		$columnMapping = array('lvl' => 'priority', 'msg' => 'message');

		$db = $registry->get('dbAdapter');
		$this->logWriter = new Zend_Log_Writer_Db($db, 'log', $columnMapping);

		$this->logger = new Zend_Log($this->logWriter);

		$this->logger->info('Informational message');
*/
	}

 	function preDispatch()
	{//*******************************************************
		// authorization
		// security

		// get rid of the view
		$this->_helper->viewRenderer->setNoRender();
	}
 	function testAction()
	{//*******************************************************
		$this->_veneerLog->info("test run");
	}
    public function __call($method, $args)
    {
		// No action
    }
}
